<%-- 
    Document   : career
    Created on : Jul 3, 2012, 1:35:25 PM
    Author     : VANANH
--%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib prefix="f" uri="http://java.sun.com/jsf/core" %>
<%@taglib prefix="h" uri="http://java.sun.com/jsf/html" %>
<%@taglib prefix="rich" uri="http://richfaces.org/rich" %>
<%@taglib prefix="a4j" uri="http://richfaces.org/a4j" %>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">

        <!-- -->
        <link rel="stylesheet" type="text/css" href="../css/popup.css"/>  
        <script type="text/javascript" language="javascript" src="../scripts/jQuery/kapi.js"></script>
    </head>
    <style>
        .items_n550{
            width: 150px !important;
        }
    </style>
    <body>
        <f:loadBundle basename="#{environmentSession.localizationSource}" var="locale"/>
        <f:view>
            <a4j:form>
                 <a4j:status onstart="#{rich:component('statPane')}.show()" onstop="#{rich:component('statPane')}.hide()" />
                <div class="action">
                    <a href="editC525.jsp?action=addC425&table=setting&height=236px&width=405px" class="fancybox add_new" id="fancybox">
                        <img src="../images/add_tab.png" alt="add" title="add" /><label> <h:outputText value="Áp dụng"/> </label>
                    </a>
                </div> 
                 <h:panelGroup id="listC525">
                    <div style="width: 100%;float: left;margin-top: 5px;">
                        <rich:dataTable rowClasses="white,blue" value="#{c525Controller.ccurpks_listoftabc525}" var="item" rowKeyVar="row">
                            <rich:column>
                                <f:facet name="header">
                                    <h:outputText value="STT"/>
                                </f:facet>
                                <div style="float: left;">
                                    <h:outputText value="#{row+1}"/>
                                </div>
                            </rich:column>
                            <rich:column>
                                <f:facet name="header">
                                    <h:outputText value="TÊN CÔNG VIỆC"/>
                                </f:facet>
                                <div style="float: left;">
                                    <h:outputText value="#{item.cv427}"/>
                                </div>
                            </rich:column>
                            <rich:column>
                                <f:facet name="header">
                                    <h:outputText value="TÊN QUY TRÌNH"/>
                                </f:facet>
                                <div style="float: left;">
                                    <h:outputText value="#{item.cv476}"/>
                                </div>
                            </rich:column>
                            <rich:column>
                                <f:facet name="header">
                                    <h:outputText value="NGƯỜI ĐẢM TRÁCH"/>
                                </f:facet>
                                <div style="float: left;">
                                    <h:outputText value="#{item.hoten}"/>
                                </div>
                            </rich:column>
                            <rich:column>
                                <f:facet name="header">
                                    <h:outputText value="ƯU TIÊN"/>
                                </f:facet>
                                <div style="float: left;">
                                    <h:outputText value="#{item.cn526}"/>
                                </div>
                            </rich:column>
                            <rich:column>
                                <f:facet name="header">
                                    <h:outputText value="MÔ TẢ"/>
                                </f:facet>
                                <div style="float: left;">
                                   <h:outputText value="#{item.cn527}"/>
                                </div>
                            </rich:column>
                            <rich:column>
                                <f:facet name="header">
                                    <h:outputText value="ACTION"/>
                                </f:facet>
                                <div style="float: left;text-align: center;width: 100%;">
                                   <%-- <h:outputLink  value="editC525.jsp?action=editC525&pc525=#{item.pc525}&height=300px&width=500px" styleClass="fancybox">
                                        <img src="../images/edit.png" alt="edit" title="edit"/>
                                    </h:outputLink>--%>
                                   <a4j:commandLink styleClass="no-decor" reRender="confirmPane"  oncomplete="#{rich:component('confirmPane')}.show()">
                                        <h:graphicImage value="/images/delete_1.png" alt="delete" />
                                        <f:param value="deleteC525" name="action"/>
                                        <f:param name="pc525" value="#{item.pc525}"/>
                                    </a4j:commandLink>
                                    <h:inputHidden value="#{c525Controller.PC525}" id="PC525"/>
                                </div>
                            </rich:column>
                        </rich:dataTable>
                    </div>
                </h:panelGroup>
                     <rich:modalPanel styleClass="pleaseimage" id="statPane" autosized="true" minHeight="10" minWidth="80"
                                 height="10" width="80" zindex="2000">
                    <h:graphicImage value="/images/loadingAnimation.gif" alt="ai" />
                </rich:modalPanel>
                <rich:modalPanel id="confirmPane" autosized="true">
                    <div class="popup1" style="height:150px; width:350px">
                        <div class="popup-header">
                            <div class="title"><h:outputText value="Thông báo"/></div>
                        </div>
                        <div class="popup-content">
                            <div class="main_content" style="padding:20px 84px">                                     
                                <font style="font-weight:bold;margin-left: 6px;">
                                <h:outputText value="Are you sure?"/>
                                </font>                                   
                            </div>
                        </div>
                        <div class="popup-footer">
                            <a4j:commandButton styleClass="buttonsave" value="Cancel" onclick="#{rich:component('confirmPane')}.hide(); return false;" />
                            <a4j:commandButton styleClass="buttonsave" value="Delete" reRender="listC525" oncomplete="#{rich:component('confirmPane')}.hide();" actionListener="#{c525Controller.stdc_tools_stornotabc525}"/>                             
                        </div>
                    </div>
                </rich:modalPanel>
            </a4j:form>
        </f:view>
    </body>
</html>
<script type="text/javascript">
    $j(document).ready(function(){
        yhight = ($j('.popup').height()-90)+"px" ;
        $j('.main_content').css('height',yhight );
        $j('.popup-content').css('height',yhight );
    });
</script>
